package application.common.render;

import javafx.beans.property.SimpleStringProperty;
import net.sf.json.JSONObject;

public final class WarningProperty {

	private final SimpleStringProperty id = new SimpleStringProperty();
	private final SimpleStringProperty suspectName = new SimpleStringProperty();
	private final SimpleStringProperty archiveNo = new SimpleStringProperty();
	private final SimpleStringProperty expireDate = new SimpleStringProperty();
	private final SimpleStringProperty cause = new SimpleStringProperty();
	private final SimpleStringProperty director = new SimpleStringProperty();
	

	public WarningProperty(JSONObject row) {
		if(row.containsKey("id")) {
			id.set(row.getString("id"));
		}
		
		if(row.containsKey("id")) {
			suspectName.set(row.getString("suspectName"));
		}
		
		if(row.containsKey("archiveNo")) {
			archiveNo.set(row.getString("archiveNo"));
		}
		
		if(row.containsKey("expireDate")) {
			expireDate.set(row.getString("expireDate"));
		}
		
		if(row.containsKey("cause")) {
			cause.set(row.getString("cause"));
		}
		
		if(row.containsKey("director")) {
			director.set(row.getString("director"));
		}
		
		
	}

	public String getId() {
		return id.get();
	}

	public String getSuspectName() {
		return suspectName.get();
	}

	public String getArchiveNo() {
		return archiveNo.get();
	}

	public String getExpireDate() {
		return expireDate.get();
	}

	public String getCause() {
		return cause.get();
	}

	public String getDirector() {
		return director.get();
	}

}
